<template>
  <!--编辑一行-->
  <tr>
    <td
      class="el-descriptions__cell el-descriptions__content is-bordered-content is-vertical-content"
      v-for="(ctrId, index) in colOrder"
      :key="'grid-edit-tr_' + ctrId + '_' + index"
    >
      <component
        :is="formItemKey[childProps[ctrId].meta.controlType]"
        :model="model"
        :meta="childProps[ctrId].meta"
        v-bind="childProps[ctrId].props"
      >
      </component>
    </td>
  </tr>
</template>

<script setup lang="ts">
  import { defineComponent } from 'vue'
  import type { IFormChildPropsList } from '../map'

  // 引入表单子控件
  import { formItemKey } from '../form-item/_map-form-item'

  const props = defineProps<{
    model: object, // 一行的 model
    childProps: IFormChildPropsList, // input de 
    colOrder: Array<number | string>
  }>()

  console.log('props===grid-edit-tr', props)

</script>